import http from "../../utils/http"

const outbound = {
    // ------------------出库客户管理
    // 获取客户列表
    getoutboundList: (data) => http.get('/customer/list', data),
    // 新增客户
    addoutbound: (data) => http.post('/customer/add', data),
    // 编辑客户
    editoutbound: (data) => http.put('/customer/edit', data),
    // 删除客户（支持单个和批量删除）
    deleteoutbound: (data) => http.delete('/customer/delete', data),
    // 切换客户状态
    switchoutbound: (data) => http.post('/customer/change_status', data),
    // 获取客户详情
    getoutboundDetails: (data) => http.get('/customer/detail', data),
    // 获取客户操作记录
    getoutboundOperationList: (data) => http.get('/customer/op_log_list', data),

    // ------------------出库订单管理
    // 获取出库订单列表
    getoutboundOrderList: (data) => http.get('/outbound_order/list', data),
    // 新增出库订单
    addoutboundOrder: (data) => http.post('/outbound_order/add', data),
    // 编辑出库订单
    editoutboundOrder: (data) => http.put('/outbound_order/edit', data),
    // 删除出库订单
    // deleteoutboundOrder: (data) => http.delete('/outbound_order/delete', data),
    // 获取出库订单详情
    getoutboundOrderDetails: (data) => http.get('/outbound_order/detail', data),
    // 提交审核
    submitAudit: (data) => http.put('/outbound_order/submit', data),
    // 审核
    audit: (data) => http.put('/outbound_order/audit', data),
    // 获取出库情况列表
    getoutboundSituationList: (data) => http.get('/outbound_order/out_product_list', data),
    // 获取补库订单操作日志
    getoutboundOrderOperationLog: (data) => http.get('/outbound_order/order_operator_log', data),

    // ------------------补库退货单管理
    // 获取补库退货单列表
    getoutboundReturnList: (data) => http.get('/outbound_return/list', data),
    // 新增补库退货单
    addoutboundReturn: (data) => http.post('/outbound_return/add', data),
    // 编辑补库退货单
    editoutboundReturn: (data) => http.put('/outbound_return/edit', data),
    // 删除补库退货单
    deleteoutboundReturn: (data) => http.delete('/outbound_return/delete', data),
    // 获取补库退货单详情
    getoutboundReturnDetails: (data) => http.get('/outbound_return/detail', data),
    // 可退货产品列表
    getoutboundReturnProductList: (data) => http.get('/outbound_order/can_return_product_list', data),
    // 根据出库订单id获取详情抽屉退货产品列表
    getoutboundReturnProductListByOrderId: (data) => http.get('/outbound_return/return_product_list', data),
    // 批量提交审核或单个提交审核
    submitAuditBatch: (data) => http.post('/outbound_return/summit', data),
    // 审核
    auditReturn: (data) => http.post('/outbound_return/audit', data),
}

export default outbound;